<!DOCTYPE html>
<html>


<!-- Mirrored from www.zi-han.net/theme/hplus/table_basic.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 20 Jan 2016 14:20:01 GMT -->
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="renderer" content="webkit">
    <title>基层组织 - {:C('WEB_TITLE')}</title>
    <meta name="keywords" content="{:C('WEB_KEYWORDS')}">
    <meta name="description" content="{:C('WEB_DESC')}">
    <!-- Sweet Alert -->
    <link rel="shortcut icon" href="__PUBLIC__/favicon.ico">
    <link href="__PUBLIC__/css/bootstrap.min14ed.css?v=3.3.6" rel="stylesheet">
    <link href="__PUBLIC__/css/font-awesome.min93e3.css?v=4.4.0" rel="stylesheet">
    <link href="__PUBLIC__/css/plugins/iCheck/custom.css" rel="stylesheet">
    <link href="__PUBLIC__/css/animate.min.css" rel="stylesheet">
    <link href="__PUBLIC__/css/style.min862f.css?v=4.1.0" rel="stylesheet">
    <link href="__PUBLIC__/css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
</head>
<style>
    table,tr,th{
        text-align: center;
    }
</style>
<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">

        <div class="col-sm-6">
            <a style="width: 100px" class="col-sm-2 J_menuItem width-20 pull-right btn btn-sm btn-primary" href="{:U('Fengcai/jc_add')}" > 添加文章</a>

            <div class="ibox float-e-margins">
                <div class="ibox-title">

                    <h5>"基层组织" 文章列表页</h5>
                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="fa fa-chevron-up"></i>
                        </a>
                    </div>
                </div>
                <div class="ibox-content">

                    <table class="table table-striped">
                        <thead>
                        <tr>
                            <th>ID</th>
                            <th>文章标题</th>
                            <th>发布人</th>
                            <th>浏览量</th>
                            <th>点赞数</th>
                            <th>发布时间</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <?php foreach ($list as $v):?>
                        <tr>
                            <td style="width: 100px;">{$v.id}</td>
                            <td style="width: 500px;">{$v.title}</td>
                            <td style="width: 100px;">{$v.name}</td>
                            <if condition="$v.read eq null">
                                <td style="width: 100px;">0</td>
                                <else/>
                                <td style="width: 100px;">{$v.reads}</td>
                            </if>
                            <if condition="$v.zan eq null">
                                <td style="width: 100px;">0</td>
                                <else/>
                                <td style="width: 100px;">{$v.zans}</td>
                            </if>
                            <td style="width: 150px;">{$v.creattime|date="Y-m-d,H:i:s",###}</td>
                            <td style="width: 200px;">
                                <!--<a href="#" class="btn btn-white btn-sm"><i class="fa fa-folder"></i> 查看 </a>-->
                                <a href="{:U('Fengcai/jc_edit',array('sid'=>$v['id']))}" class="btn btn-white btn-sm"><i class="fa fa-pencil"></i> 编辑 </a>
                                <a class="btn btn-white btn-sm qwq" datas="{$v.id}"  onclick=" return false;"><i class="fa fa-close"></i> 删除 </a>
                            </td>
                        </tr>
                        <?php endforeach;?>
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<style>
    .pages{
        text-align: center;
    }
    .pages a,.pages span {
        display:inline-block;
        padding:2px 5px;
        margin:0 1px;
        border:1px solid #f0f0f0;
        -webkit-border-radius:3px;
        -moz-border-radius:3px;
        border-radius:3px;
    }
    .pages a,.pages li {
        display:inline-block;
        list-style: none;
        text-decoration:none; color:#58A0D3;
    }
    .pages a.first,.pages a.prev,.pages a.next,.pages a.end{
        margin:0;
    }
    .pages a:hover{
        border-color:#50A8E6;
    }
    .pages span.current{
        background:#50A8E6;
        color:#FFF;
        font-weight:700;
        border-color:#50A8E6;
    }
</style>
<div class="pages">
    {$page}
</div>
<script src="__PUBLIC__/js/jquery.min.js?v=2.1.4"></script>
<script src="__PUBLIC__/js/bootstrap.min.js?v=3.3.6"></script>
<script src="__PUBLIC__/js/plugins/peity/jquery.peity.min.js"></script>
<script src="__PUBLIC__/js/content.min.js?v=1.0.0"></script>
<script src="__PUBLIC__/js/plugins/iCheck/icheck.min.js"></script>
<script src="__PUBLIC__/js/demo/peity-demo.min.js"></script>
<script src="__PUBLIC__/js/plugins/sweetalert/sweetalert.min.js"></script>
<script>
    $(document).ready(function(){$(".i-checks").iCheck({checkboxClass:"icheckbox_square-green",radioClass:"iradio_square-green",})});
</script>
<script type="text/javascript" src="http://tajs.qq.com/stats?sId=9051096" charset="UTF-8"></script>
</body>
<script>
    $('.qwq').click(function (e) {
        swal({
            title: "您确定要删除这条信息吗",
            text: "删除后将无法恢复，请谨慎操作！",
            type: "warning",
            showCancelButton: true,
            confirmButtonColor: "#DD6B55",
            confirmButtonText: "删除",
            cancelButtonText: "取消",
            closeOnConfirm: false
        }, function () {
            var a = e.currentTarget.getAttribute('datas');
            $url = "{:U('Fengcai/jc_del')}";
            $data = {'id':a};
            $.post($url,$data,function(env){
                if(env == 'ok') {
                    swal("删除成功！", "您已经永久删除了这条信息。", "success");
                    setTimeout(function () {
                        window.history.go(0);
                    },2000)
                } else {
                    swal("删除失败！", "请联系技术人员！。", "error");
                    setTimeout(function () {
                        window.history.go(0);
                    },4000)
                }
            },'json');

        });
    });
</script>

<!-- Mirrored from www.zi-han.net/theme/hplus/table_basic.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 20 Jan 2016 14:20:01 GMT -->
</html>
